import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.Frame;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;

import javax.imageio.ImageIO;


public class GameWindowAWT extends Frame
{
	private static final long serialVersionUID = 1L;
	private BoardAWT board = new BoardAWT();
	
	public GameWindowAWT()
	{
		this.addWindowListener(new WindowAdapter()
		{
			public void windowClosing(WindowEvent e)
			{
				System.exit(0);
			}
		});
		this.setBackground(Color.BLACK);
		this.setTitle("FourInARow");
		this.setResizable(false);
		this.add(board,BorderLayout.CENTER);	
		BufferedImage icon ;
		try 
		{
			icon = ImageIO.read(new File("D:\\JAVA\\Projektek\\FourInARow\\src\\res\\icon2.png"));
			this.setIconImage(icon);
		} 
		catch (IOException e1) {}

	}
	
	public static void main(String[] args)
	{
		GameWindowAWT window = new GameWindowAWT();
		window.setBounds(0, 0, 640, 480);
		window.setVisible(true);
	}
	
}
